﻿@{
    ViewBag.Title = "Home Page";
}
@section featured {
    <section class="featured">
        <div class="content-wrapper">
            <hgroup class="title">
                <h1>@Trust.Casas.Resources.Strings.AppName.</h1>
                <h2>@ViewBag.Message</h2>
            </hgroup>
            <p>
            </p>
        </div>
    </section>
}
<input type="button" name="name" value="Map" onclick="$('#myMapHolder').load('@Url.Action("Map", "Home")    ')" />
<div id="myMapHolder"></div>
<input type="button" name="name" value="Map" onclick="myfunction();" />
<script type="text/javascript">
    var repo;

    $(document).ready(function () {
        require(['Trust.Api'], function (api) {
            repo = new RegionRepository();
            
        });
    });

    function myfunction() {
        var rest = repo.getItems({$top:1});
        rest.success(function(data){alert(data);});
    }
</script>


